<?php


class MyRedis {
    private static $_instance;
    public static function getInstance() {
        if (!isset(self::$_instance)) {
            self::$_instance = new Redis();
            self::$_instance->connect(REDIS_HOST, REDIS_PORT);
            self::$_instance->auth(REDIS_AUTH);
        }
        return self::$_instance;
    }
}